package com.s6.sort1;

import java.util.Arrays;
import java.util.Random;

public class ArrayUtils {

	private static final Random random = new Random();

	public static int[] randomInt(int length) {
		int[] array = new int[length];
		for (int i = 0; i < array.length; i++) {
			array[i] = random.nextInt(13);
		}
		return array;
	}

	public static int[] randomInt() {
		return randomInt(7);
	}

	public static void print(int[] array) {
		System.out.println(Arrays.toString(array));
	}

	public static void swap(int[] array, int i, int j) {
		if (i != j) {
			int temp = array[i];
			array[i] = array[j];
			array[j] = temp;
		}
	}
}
